home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus 1995 #5 & #6
/
Amiga Plus CD - 1995 - No. 5 and 6.iso
/
pd
/
netz
/
envoyempire
/
source
/
muiempire.service
/
muiempireservicetest.c
< prev
next >
Wrap
C/C++ Source or Header
|
1995-07-10
|
1KB
|
42 lines
#include "proto/exec.h"
#include "proto/dos.h"
#include "MUIEmpire_pragmas.h"
#include <stdio.h>
#include <utility/tagitem.h>
#include <pragmas/utility_pragmas.h>
#include <clib/utility_protos.h>
#include <envoy/nipc.h>
#include <envoy/services.h>
char __stdiowin[] = "con:0/0/640/100";
struct Library *MUIEmpireBase;
main()
{
int ret;
struct TagItem cptags[2];
char name[20];
MUIEmpireBase = OpenLibrary("MUIEmpire.service",0);
if (MUIEmpireBase)
{
cptags[0].ti_Tag = SSVC_EntityName;
cptags[0].ti_Data = (ULONG)name;
cptags[1].ti_Tag = TAG_DONE;
cptags[1].ti_Data = NULL;
printf("Library Opened Sucessfully.\n");
ret = StartServiceA(cptags);
printf("test1 returned = %d\n", ret);
printf("Name %s\n",(char *)cptags[0].ti_Data);
CloseLibrary(MUIEmpireBase);
printf("Library Closed.\n");
Delay(200);
}
else printf("failed to open library!\n");
}